package com.xxl.job.executor.service.jobhandler;

import com.xxl.job.executor.annotation.AsyncCommonJob;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;

/**
 * @author lukaidong
 * @date 2024/02/25
 * @description
 */
@Component
public class BatchJob01 {
    private static Logger logger = LoggerFactory.getLogger(BatchJob01.class);

    @AsyncCommonJob(jobName = "batchJob01")
    public void execute() throws Exception {
        long startTime = System.currentTimeMillis();
        logger.info("执行定时任务batchJob01，开始...，开始时间：{}", startTime);
//        Thread.sleep(60 * 1000);
        logger.info("执行定时任务batchJob01，结束...，开始时间：{}", startTime);
    }

}
